<?php

class status_SearchController extends Zend_Controller_Action
{
  function init() {
  	header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1
	header("Expires: Sat, 26 Jul 1997 05:00:00 GMT"); // Date in the past
    $this->getHelper('viewRenderer')->setNoRender();
  }


	//creation of a new status for the user
	function indexAction() {
	
		require_once('status/objects/status.php');
		//only accepted param is q

		$results = Status_Object_Status::search($this->_getParam('q'));
		
		$data['status'] = 	'OK';
		$data['data'] = $results;
		
		echo Zend_Registry::get('dt_serializer')->serialize($data);
    	return;	
		
		
	} //end function index
  
} //End class

